Integrand size = 33, antiderivative size = 86 \[ \int \frac {A+B \sec (c+d x)}{\cos ^{\frac {3}{2}}(c+d x) (a+b \sec (c+d x))} \, dx=-\frac {2 B E\left (\left .\frac {1}{2} (c+d x)\right |2\right )}{b d}+\frac {2 (A b-a B) \operatorname {EllipticPi}\left (\frac {2 a}{a+b},\frac {1}{2} (c+d x),2\right )}{b (a+b) d}+\frac {2 B \sin (c+d x)}{b d \sqrt {\cos (c+d x)}} \]
[Out]
Time = 0.44 (sec) , antiderivative size = 86, normalized size of antiderivative = 1.00, number of steps used = 6, number of rules used = 6, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.182, Rules used = {3033, 3079, 3138, 2719, 12, 2884} \[ \int \frac {A+B \sec (c+d x)}{\cos ^{\frac {3}{2}}(c+d x) (a+b \sec (c+d x))} \, dx=\frac {2 (A b-a B) \operatorname {EllipticPi}\left (\frac {2 a}{a+b},\frac {1}{2} (c+d x),2\right )}{b d (a+b)}-\frac {2 B E\left (\left .\frac {1}{2} (c+d x)\right |2\right )}{b d}+\frac {2 B \sin (c+d x)}{b d \sqrt {\cos (c+d x)}} \]
[In]
[Out]
Rule 12
Rule 2719
Rule 2884
Rule 3033
Rule 3079
Rule 3138
Rubi steps \begin{align*} \text {integral}& = \int \frac {B+A \cos (c+d x)}{\cos ^{\frac {3}{2}}(c+d x) (b+a \cos (c+d x))} \, dx \\ & = \frac {2 B \sin (c+d x)}{b d \sqrt {\cos (c+d x)}}+\frac {2 \int \frac {\frac {1}{2} (A b-a B)-\frac {1}{2} b B \cos (c+d x)-\frac {1}{2} a B \cos ^2(c+d x)}{\sqrt {\cos (c+d x)} (b+a \cos (c+d x))} \, dx}{b} \\ & = \frac {2 B \sin (c+d x)}{b d \sqrt {\cos (c+d x)}}-\frac {2 \int -\frac {a (A b-a B)}{2 \sqrt {\cos (c+d x)} (b+a \cos (c+d x))} \, dx}{a b}-\frac {B \int \sqrt {\cos (c+d x)} \, dx}{b} \\ & = -\frac {2 B E\left (\left .\frac {1}{2} (c+d x)\right |2\right )}{b d}+\frac {2 B \sin (c+d x)}{b d \sqrt {\cos (c+d x)}}+\frac {(A b-a B) \int \frac {1}{\sqrt {\cos (c+d x)} (b+a \cos (c+d x))} \, dx}{b} \\ & = -\frac {2 B E\left (\left .\frac {1}{2} (c+d x)\right |2\right )}{b d}+\frac {2 (A b-a B) \operatorname {EllipticPi}\left (\frac {2 a}{a+b},\frac {1}{2} (c+d x),2\right )}{b (a+b) d}+\frac {2 B \sin (c+d x)}{b d \sqrt {\cos (c+d x)}} \\ \end{align*}
Leaf count is larger than twice the leaf count of optimal. \(206\) vs. \(2(86)=172\).
Time = 2.79 (sec) , antiderivative size = 206, normalized size of antiderivative = 2.40 \[ \int \frac {A+B \sec (c+d x)}{\cos ^{\frac {3}{2}}(c+d x) (a+b \sec (c+d x))} \, dx=\frac {\frac {2 (2 A b-3 a B) \operatorname {EllipticPi}\left (\frac {2 a}{a+b},\frac {1}{2} (c+d x),2\right )}{a+b}-\frac {2 b B \left (2 \operatorname {EllipticF}\left (\frac {1}{2} (c+d x),2\right )-\frac {2 b \operatorname {EllipticPi}\left (\frac {2 a}{a+b},\frac {1}{2} (c+d x),2\right )}{a+b}\right )}{a}+\frac {4 B \sin (c+d x)}{\sqrt {\cos (c+d x)}}-\frac {2 B \left (-2 a b E\left (\left .\arcsin \left (\sqrt {\cos (c+d x)}\right )\right |-1\right )+2 b (a+b) \operatorname {EllipticF}\left (\arcsin \left (\sqrt {\cos (c+d x)}\right ),-1\right )+\left (a^2-2 b^2\right ) \operatorname {EllipticPi}\left (-\frac {a}{b},\arcsin \left (\sqrt {\cos (c+d x)}\right ),-1\right )\right ) \sin (c+d x)}{a b \sqrt {\sin ^2(c+d x)}}}{2 b d} \]
[In]
[Out]
Leaf count of result is larger than twice the leaf count of optimal. \(297\) vs. \(2(136)=272\).
Time = 9.33 (sec) , antiderivative size = 298, normalized size of antiderivative = 3.47
method | result | size |
default | \(-\frac {\sqrt {-\left (-2 \cos \left (\frac {d x}{2}+\frac {c}{2}\right )^{2}+1\right ) \sin \left (\frac {d x}{2}+\frac {c}{2}\right )^{2}}\, \left (\frac {2 B \sqrt {-2 \sin \left (\frac {d x}{2}+\frac {c}{2}\right )^{4}+\sin \left (\frac {d x}{2}+\frac {c}{2}\right )^{2}}\, \left (2 \cos \left (\frac {d x}{2}+\frac {c}{2}\right ) \sin \left (\frac {d x}{2}+\frac {c}{2}\right )^{2}-\sqrt {\frac {1}{2}-\frac {\cos \left (d x +c \right )}{2}}\, \operatorname {EllipticE}\left (\cos \left (\frac {d x}{2}+\frac {c}{2}\right ), \sqrt {2}\right ) \sqrt {2 \sin \left (\frac {d x}{2}+\frac {c}{2}\right )^{2}-1}\right )}{b \sin \left (\frac {d x}{2}+\frac {c}{2}\right )^{2} \left (2 \sin \left (\frac {d x}{2}+\frac {c}{2}\right )^{2}-1\right )}-\frac {2 \left (A b -B a \right ) a \sqrt {\frac {1}{2}-\frac {\cos \left (d x +c \right )}{2}}\, \sqrt {-2 \cos \left (\frac {d x}{2}+\frac {c}{2}\right )^{2}+1}\, \operatorname {EllipticPi}\left (\cos \left (\frac {d x}{2}+\frac {c}{2}\right ), \frac {2 a}{a -b}, \sqrt {2}\right )}{b \left (a^{2}-a b \right ) \sqrt {-2 \sin \left (\frac {d x}{2}+\frac {c}{2}\right )^{4}+\sin \left (\frac {d x}{2}+\frac {c}{2}\right )^{2}}}\right )}{\sin \left (\frac {d x}{2}+\frac {c}{2}\right ) \sqrt {2 \cos \left (\frac {d x}{2}+\frac {c}{2}\right )^{2}-1}\, d}\) | \(298\) |
[In]
[Out]
Timed out. \[ \int \frac {A+B \sec (c+d x)}{\cos ^{\frac {3}{2}}(c+d x) (a+b \sec (c+d x))} \, dx=\text {Timed out} \]
[In]
[Out]
\[ \int \frac {A+B \sec (c+d x)}{\cos ^{\frac {3}{2}}(c+d x) (a+b \sec (c+d x))} \, dx=\int \frac {A + B \sec {\left (c + d x \right )}}{\left (a + b \sec {\left (c + d x \right )}\right ) \cos ^{\frac {3}{2}}{\left (c + d x \right )}}\, dx \]
[In]
[Out]
\[ \int \frac {A+B \sec (c+d x)}{\cos ^{\frac {3}{2}}(c+d x) (a+b \sec (c+d x))} \, dx=\int { \frac {B \sec \left (d x + c\right ) + A}{{\left (b \sec \left (d x + c\right ) + a\right )} \cos \left (d x + c\right )^{\frac {3}{2}}} \,d x } \]
[In]
[Out]
\[ \int \frac {A+B \sec (c+d x)}{\cos ^{\frac {3}{2}}(c+d x) (a+b \sec (c+d x))} \, dx=\int { \frac {B \sec \left (d x + c\right ) + A}{{\left (b \sec \left (d x + c\right ) + a\right )} \cos \left (d x + c\right )^{\frac {3}{2}}} \,d x } \]
[In]
[Out]
Timed out. \[ \int \frac {A+B \sec (c+d x)}{\cos ^{\frac {3}{2}}(c+d x) (a+b \sec (c+d x))} \, dx=\int \frac {A+\frac {B}{\cos \left (c+d\,x\right )}}{{\cos \left (c+d\,x\right )}^{3/2}\,\left (a+\frac {b}{\cos \left (c+d\,x\right )}\right )} \,d x \]
[In]
[Out]